//
//  DMPurchaseInfo.h
//  DualMediationSDK
//
//  购买信息模型类
//

#import <Foundation/Foundation.h>
#import "DMLifecycleTypes.h"

NS_ASSUME_NONNULL_BEGIN

/**
 * 购买信息模型
 * 用于封装应用内购买的相关信息
 */
@interface DMPurchaseInfo : NSObject

/**
 * 产品ID
 */
@property (nonatomic, strong) NSString *productId;

/**
 * 购买ID/交易ID
 */
@property (nonatomic, strong) NSString *purchaseId;

/**
 * 交易ID (别名，与purchaseId相同)
 */
@property (nonatomic, strong) NSString *transactionId;

/**
 * 产品类型
 */
@property (nonatomic, assign) DMProductType productType;

/**
 * 购买时间戳
 */
@property (nonatomic, strong, nullable) NSNumber *purchaseTime;

/**
 * 购买价格
 */
@property (nonatomic, strong, nullable) NSString *price;

/**
 * 货币代码
 */
@property (nonatomic, strong, nullable) NSString *currencyCode;

/**
 * 收据数据
 */
@property (nonatomic, strong, nullable) NSData *receiptData;

/**
 * 是否为恢复购买
 */
@property (nonatomic, assign) BOOL isRestored;

/**
 * 购买状态描述
 */
@property (nonatomic, strong, nullable) NSString *statusDescription;

/**
 * 额外信息字典
 */
@property (nonatomic, strong, nullable) NSDictionary *extraInfo;

@end

NS_ASSUME_NONNULL_END